var map = new BMap.Map("nowcity");

function myFun(result) {
	var cityName = result.name;
	map.setCenter(cityName);
	$(".nowcity").html(cityName);
}
var myCity = new BMap.LocalCity();
myCity.get(myFun);

// var map = new BMap.Map("nowcity");

// var geolocation = new BMap.Geolocation();
// geolocation.getCurrentPosition(function(r){
// 	  console.log(r.address);
// 	  $(".nowcity").html(r.address.city);
// });
function fun1() {
	$("div.top-list1")[0].style.display = "none";
	$("div.top-list2")[0].style.display = "block";
}
function fun2() {
	$("div.top-list1")[0].style.display = "block";
	$("div.top-list2")[0].style.display = "none";
}
$(document).scroll(function() {
	var scroH = $(document).scrollTop(); //滚动高度
	if (scroH > 190) { //距离顶部大于100px时
		$(".jj_top-menu").css({
			"position": "fixed",
			"left": "160px",
			"top": "10px"
		});
	}
	if (scroH < 190) { //距离顶部大于100px时
		$(".jj_top-menu").css({
			"position": "relative",
			"left": "0",
			"top": "0"
		});
	}
	
});
